import React from 'react'
import { NavBar, Space, Toast } from 'antd-mobile'
import { useNavigate } from 'react-router-dom'

function Navbar(props) {
    let navigate=useNavigate()
    const {title,url}=props
  return (
    <div>
      <NavBar onBack={()=>navigate(url||-1)}>{title}</NavBar>
    </div>
  )
}

export default Navbar
